package cn.abcsys.cloud.devops.pipeline.common;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.PropertySource;

//@Component("systemConfig")
@Configuration
@PropertySource(value="classpath:config/system.properties")
public class SystemConfig {
	@Value("${jenkins.workspace}")
	private String jenkinsWorkspace;
	@Value("${jenkins.user}")
	private String jenkinsUser;
	@Value("${jenkins.pwd}")
	private String jenkinsPwd;
	@Value("${jenkins.url}")
	private String jenkinsUrl;
	
	@Value("${jenkins.strategy.daysToKeep}")
	private int jenkinsDaysToKeep;
	@Value("${jenkins.strategy.numToKeep}")
	private int jenkinsNumToKeep;
	
	@Value("${pipeline.host.ip}")
	private String pipelineHostIp;
	@Value("${pipeline.host.user}")
	private String pipelineHostUser;
	@Value("${pipeline.host.pwd}")
	private String pipelineHostPwd;
	@Value("${image.clair.logs.path}")
	private String imageClairLogsPath;
	
	public String getJenkinsWorkspace() {
		return jenkinsWorkspace;
	}
	public void setJenkinsWorkspace(String jenkinsWorkspace) {
		this.jenkinsWorkspace = jenkinsWorkspace;
	}
	public String getJenkinsUser() {
		return jenkinsUser;
	}
	public void setJenkinsUser(String jenkinsUser) {
		this.jenkinsUser = jenkinsUser;
	}
	public String getJenkinsPwd() {
		return jenkinsPwd;
	}
	public void setJenkinsPwd(String jenkinsPwd) {
		this.jenkinsPwd = jenkinsPwd;
	}
	public String getJenkinsUrl() {
		return jenkinsUrl;
	}
	public void setJenkinsUrl(String jenkinsUrl) {
		this.jenkinsUrl = jenkinsUrl;
	}
	public int getJenkinsDaysToKeep() {
		return jenkinsDaysToKeep;
	}
	public void setJenkinsDaysToKeep(int jenkinsDaysToKeep) {
		this.jenkinsDaysToKeep = jenkinsDaysToKeep;
	}
	public int getJenkinsNumToKeep() {
		return jenkinsNumToKeep;
	}
	public void setJenkinsNumToKeep(int jenkinsNumToKeep) {
		this.jenkinsNumToKeep = jenkinsNumToKeep;
	}
	public String getPipelineHostIp() {
		return pipelineHostIp;
	}
	public void setPipelineHostIp(String pipelineHostIp) {
		this.pipelineHostIp = pipelineHostIp;
	}
	public String getPipelineHostUser() {
		return pipelineHostUser;
	}
	public void setPipelineHostUser(String pipelineHostUser) {
		this.pipelineHostUser = pipelineHostUser;
	}
	public String getPipelineHostPwd() {
		return pipelineHostPwd;
	}
	public void setPipelineHostPwd(String pipelineHostPwd) {
		this.pipelineHostPwd = pipelineHostPwd;
	}
	public String getImageClairLogsPath() {
		return imageClairLogsPath;
	}
	public void setImageClairLogsPath(String imageClairLogsPath) {
		this.imageClairLogsPath = imageClairLogsPath;
	}
}
